package com.doctcloud.hisinfo.api;

import com.doctcloud.common.core.constant.ServiceNameConstants;
import com.doctcloud.hisinfo.api.factory.RemoteHisOrdadmFallbackFactory;
import com.doctcloud.hisinfo.histable.domain.ordadm.OrdersCostsDo;
import com.doctcloud.hisinfo.histable.domain.ordadm.OrdersDo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(contextId = "remoteOrdadmService", value = ServiceNameConstants.HIS_ORDADM_SERVICE, fallbackFactory = RemoteHisOrdadmFallbackFactory.class)
public interface RemoteHisOrdadmService {
    @GetMapping("/ordadm/ordercosts/listbypat")
    public List<OrdersCostsDo> getOrdersCostsById(@RequestParam("patientId")String patientId,
                                                     @RequestParam("visitId")Integer visitId);
    @GetMapping("/ordadm/orders/listbypat")
    public List<OrdersDo> listOrdersByPat(@RequestParam("patientId")String patientId,
                                       @RequestParam("visitId")Integer visitId);
}
